params["_target","_unit","_id"];

_target removeAction _id;


private _pos = _unit getPos [25, random 360];
private _box = "CargoNet_01_box_F" createVehicle _pos;

//这个函数只能服务器调用才有效
[_box, -1] remoteExec ['fn_createSupply', 2];

//________________________________________添加物品____________________________
private _r1 = floor random 3;

private _vs =[
"V_DeckCrew_brown_F",
"V_DeckCrew_white_F",
"V_DeckCrew_violet_F",
"V_DeckCrew_red_F",
"V_DeckCrew_green_F",
"V_DeckCrew_blue_F",
"V_DeckCrew_yellow_F"
];

//背心 x1
_box addItemCargoGlobal [selectRandom _vs, 1];



//急救箱 x12
_box addItemCargoGlobal ["FirstAidKit", 2 + floor random 3];

//望远镜 x1
if(random 100 < 12) then
{
	_box addItemCargoGlobal ["Binocular", 1];
};

//夜视仪 x2
if(random 100 < 25) then
{
	_box addItemCargoGlobal ["O_NVGoggles_ghex_F", 1];
};



//RGN x8
_box addItemCargoGlobal ["MiniGrenade", 1 + floor random 2];

//烟雾弹 x16
_box addItemCargoGlobal ["SmokeShell", 2 + floor random 4];

//指南针
if(random 100 < 80) then
{
	_box addItemCargoGlobal ["ItemCompass", 1];
};


//UAV
if(random 100 < 15) then
{
	_box addItemCargoGlobal ["O_UavTerminal", 1];
};


//随机荧光弹
_box addItemCargoGlobal [selectRandom ["Chemlight_blue", "Chemlight_red", "Chemlight_green", "Chemlight_yellow"], 1];

